import http from '../utils/http'

//获得产品详情查询
export const getProductInfo=(pid,ptype)=>{
  return http.get(`/productdetail/getProductInfo`,{'pid':pid,'ptype':ptype})
}

//根据id查询套餐
export const getTProductById=(id)=>{
  return http.get(`/tproduct/getTProductById`,{'id':id})
}

//根据id查询单个产品
export const getProductById=(id)=>{
  return http.get(`/product/getProductById`,{'id':id})
}

//查询商品评论
export const getProductComment=(pid,ptype)=>{
  return http.get(`/comment/getProductComment`,{'pid':pid,'ptype':ptype})
}

 /** 查看商品对象
 * @param {*} product_detail_id 
 */
export const reqPro=(product_detail_id)=>{
  return http.get(`/productdetail/pro`,{'product_detail_id':product_detail_id})
}
/**
 * 查看开园时间
 * @param {*} product_id 
 */
export const reqTimesss=(product_id)=>{
  return http.get(`/productdetail/timesss`,{'product_id':product_id})
}
/**
 * 删除评论
 * @param {*} id 
 */
export const reqClearljt=(id)=>{
  return http.get(`/comment/clearljt`,{'id':id})
}

export const proname=(pid)=>{
  return http.get(`/product/proname`,{'pid':pid})
}